package com.mysteel.search.vo;

import com.mysteel.common.to.es.SkuEsModel;
import lombok.Data;

import java.util.ArrayList;
import java.util.List;

/**
 * ProjectName: mail
 * ClassName: SearchResponse
 * Description:
 * date: 2021/01/29/029 9:16
 *
 * @author xiaochao
 */
@Data
public class SearchResult {
    /**
     * 商品信息
     */
    private List<SkuEsModel> products;

    /**
     * 分页信息
     */
    private Integer currentPageNum;

    private Long totalCount;

    private Integer totalPage;

    /**
     * 分页导航
     */
    private List<Integer> pageNavs;

    /**
     * 查询结果涉及的所有品牌
     */
    private List<BrandVo> brands;

    /**
     * 所有可筛选属性
     */
    private List<AttrVo> attrs;

    private List<Long> attrIds;
    /**
     * 所有可筛选的分类信息
     */
    private List<CatalogVo> catalogs;

    /**
     * 面包屑导航
     */
    private List<NavVo> navs = new ArrayList<>(0);

    @Data
    public static class NavVo{
        private String navName;
        private String navValue;
        private String linkUrl;
    }

    @Data
    public static class BrandVo{
        private Long brandId;
        private String brandName;
        private String brandImg;
    }

    @Data
    public static class AttrVo{
        private Long attrId;
        private String attrName;
        private List<String> attrValue;
    }

    @Data
    public static class CatalogVo{
        private Long catalogId;
        private String catalogName;
    }
}
